package com.ysh.blog.pojo;

public class Page {
    int page;
    Integer count;
    Integer start;


    public Page(Integer page, Integer count) {
        if(page==null){
            this.page=1;
        }else {
            this.page = page;
        }
        if(count==null){
            this.count=5;
        }else {
            this.count = count;
        }

        if(this.page>=1){
            this.start= ( this.page-1)* this.count;
        }

    }


    public int getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public int getStart() {
        return start;
    }

    public void setStart(int start) {
        this.start = start;
    }
}
